-
Notifications
You must be signed in to change notification settings - Fork 60
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add support for transforming Checkstyle XML output to JUnit XML #283
Conversation
Looks like the previous result failed on some format errors; I've ran the formatters buildifier and google-java-format |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Apologies for taking so long to review this: we needed to fix the CI tests first, and that took longer than expected. Thank you for your patience.
You may need to rebase past e736106 and re-run the |
59c03d0
to
519a795
Compare
@shs96c I rebased and ran the formatter again. Also, I think there is an escape impurity.
|
The windows issue looks transient. |
(retrying the tests) |
Bazel will natively create a
test.xml
for all test runners if they do not create one themselves.For the checkstyle test-runner it would create a test.xml that captures the system-out.
JUnit is a well establish format and well known by many CI programs.
Having the checkstyle rule itself create a more curated JUnit XML file is in the user's best interest.
In this PR, we modify the checkstyle rules to emit a
test.xml
itself, stopping Bazel from implicitly doing so.We have checkstyle emit the XML format always and then use a very minimal Java tool and a provided default XLST (XML stylesheet) to transform the Checkstyle XML to one following JUnit's XML specification.